package com.AICoupon.controller;


import com.AICoupon.aiservice.ConsultantService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import reactor.core.publisher.Flux;

@RestController
public class DemoController {
    @Autowired
    private ConsultantService consultantService;

    @RequestMapping(value = "/demo",produces = "text/html;charset=utf-8")
    public Flux<String> demo(String memoryId,String message) {
        Flux<String> result = consultantService.chat(memoryId,message);
        return result;
    }
}
